home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1996 May: Tool Chest / Developer CD Series May 1996 (Tool Chest) (Apple Computer) (1996).iso / Tool Chest / Development Tools & Languages / Macintosh Common Lisp Related / interfaces / PInterface Translator / PInterfaces / MediaHandlers.p < prev    next >
Encoding:
Text File  |  1993-09-16  |  5.6 KB  |  160 lines  |  [TEXT/MPS ]

  1. {************************************************************
  2.  
  3. Created: Thursday, August 20, 1992 at 12:09 AM
  4.  MediaHandler.h
  5.  C Interface to the Macintosh Libraries
  6.  
  7.  
  8.  Copyright Apple Computer, Inc. 1991, 1992
  9.  All rights reserved
  10.  
  11. ************************************************************}
  12.  
  13.  
  14. {$IFC UNDEFINED UsingIncludes}
  15. {$SETC UsingIncludes := 0}
  16. {$ENDC}
  17.  
  18. {$IFC NOT UsingIncludes}
  19.  UNIT MediaHandlers;
  20.  INTERFACE
  21. {$ENDC}
  22.  
  23. {$IFC UNDEFINED UsingMediaHandlers}
  24. {$SETC UsingMediaHandlers := 1}
  25.  
  26. {$I+}
  27. {$SETC MediaHandlersIncludes := UsingIncludes}
  28. {$SETC UsingIncludes := 1}
  29. {$IFC UNDEFINED UsingMovies}
  30. {$I $$Shell(PInterfaces)Movies.p}
  31. {$ENDC}
  32.  
  33. {$SETC UsingIncludes := MediaHandlersIncludes}
  34.  
  35. CONST
  36. handlerHasSpatial = $1;
  37. handlerCanClip = $2;
  38. handlerCanMatte = $4;
  39. handlerCanTransferMode = $8;
  40. handlerNeedsBuffer = $10;
  41. handlerNoIdle = $20;
  42. handlerNoScheduler = $40;
  43. handlerWantsTime = $80;
  44. handlerCGrafPortOnly = $100;
  45.  
  46. mMustDraw = $8;
  47. mAtEnd = $10;
  48. mPreflightDraw = $20;
  49.  
  50. mDidDraw = $1;
  51. mNeedsToDraw = $4;
  52.  
  53. TYPE
  54.  
  55. GetMovieCompleteParams = RECORD
  56.     version : INTEGER;
  57.     theMovie: Movie;
  58.     theTrack: Track;
  59.     theMedia: Media;
  60.     movieScale: TimeScale;
  61.     mediaScale: TimeScale;
  62.     movieDuration: TimeValue;
  63.     trackDuration: TimeValue;
  64.     mediaDuration: TimeValue;
  65.     effectiveRate: Fixed;
  66.     timeBase:TimeBase;
  67.     volume:INTEGER;
  68.     width:Fixed;
  69.     height:Fixed;
  70.     trackMovieMatrix:MatrixRecord;
  71.     moviePort:CGrafPtr;
  72.     movieGD:GDHandle;
  73.     trackMatte:PixMapHandle;
  74. END;
  75.  
  76. CONST
  77. kMediaInitializeSelect = $501;
  78. kMediaSetHandlerCapabilitiesSelect = $502;
  79. kMediaIdleSelect = $503;
  80. kMediaGetMediaInfoSelect = $504;
  81. kMediaPutMediaInfoSelect = $505;
  82. kMediaSetActiveSelect = $506;
  83. kMediaSetRateSelect = $507;
  84. kMediaGGetStatusSelect = $508;
  85. kMediaTrackEditedSelect = $509;
  86. kMediaSetMediaTimeScaleSelect = $50A;
  87. kMediaSetMovieTimeScaleSelect = $50B;
  88. kMediaSetGWorldSelect = $50C;
  89. kMediaSetDimensionsSelect = $50D;
  90. kMediaSetClipSelect = $50E;
  91. kMediaSetMatrixSelect = $50F;
  92. kMediaGetTrackOpaqueSelect = $510;
  93. kMediaSetGraphicsModeSelect = $511;
  94. kMediaGetGraphicsModeSelect = $512;
  95. kMediaGSetVolumeSelect = $513;
  96. kMediaSetSoundBalanceSelect = $514;
  97. kMediaGetSoundBalanceSelect = $515;
  98. kMediaGetNextBoundsChangeSelect = $516;
  99. kMediaGetSrcRgnSelect = $517;
  100. kMediaPrerollSelect = $518;
  101.  
  102. FUNCTION MediaInitialize (ci:ComponentInstance; VAR gmc : GetMovieCompleteParams):ComponentResult; 
  103.  INLINE $2F3C,$4,$501,$7000,$A82A;
  104. FUNCTION MediaSetHandlerCapabilities (ci:ComponentInstance; flags:LONGINT; flagsMask:LONGINT ):ComponentResult; 
  105.  INLINE $2F3C,$8,$502,$7000,$A82A;
  106. FUNCTION MediaIdle (ci:ComponentInstance; atMediaTime:TimeValue; flagsIn:LONGINT ; VAR flagsOut:LONGINT; VAR movieTime:TimeRecord):ComponentResult; 
  107.  INLINE $2F3C,$10,$503,$7000,$A82A;
  108. FUNCTION MediaGetMediaInfo (ci:ComponentInstance; h:Handle):ComponentResult; 
  109.  INLINE $2F3C,$4,$504,$7000,$A82A;
  110. FUNCTION MediaPutMediaInfo (ci:ComponentInstance; h:Handle):ComponentResult; 
  111.  INLINE $2F3C,$4,$505,$7000,$A82A;
  112. FUNCTION MediaSetActive (ci:ComponentInstance ; enableMedia:BOOLEAN  ):ComponentResult; 
  113.  INLINE $2F3C,$2,$506,$7000,$A82A;
  114. FUNCTION MediaSetRate (ci:ComponentInstance; rate:Fixed  ):ComponentResult; 
  115.  INLINE $2F3C,$4,$507,$7000,$A82A;
  116. FUNCTION MediaGGetStatus (ci:ComponentInstance; VAR statusErr:ComponentResult ):ComponentResult; 
  117.  INLINE $2F3C,$4,$508,$7000,$A82A;
  118. FUNCTION MediaTrackEdited (ci:ComponentInstance):ComponentResult; 
  119.  INLINE $2F3C,$0,$509,$7000,$A82A;
  120. FUNCTION MediaSetMediaTimeScale (ci:ComponentInstance; newTimeScale:TimeScale  ):ComponentResult; 
  121.  INLINE $2F3C,$4,$50A,$7000,$A82A;
  122. FUNCTION MediaSetMovieTimeScale (ci:ComponentInstance ; newTimeScale:TimeScale  ):ComponentResult; 
  123.  INLINE $2F3C,$4,$50B,$7000,$A82A;
  124. FUNCTION MediaSetGWorld (ci:ComponentInstance; aPort:CGrafPtr; aGD:GDHandle ):ComponentResult;
  125.  INLINE $2F3C,$8,$50C,$7000,$A82A;
  126. FUNCTION MediaSetDimensions ( ci:ComponentInstance; width:Fixed; height:Fixed ) :ComponentResult;
  127.  INLINE $2F3C,$8,$50D,$7000,$A82A;
  128. FUNCTION MediaSetClip (ci:ComponentInstance;theClip:RgnHandle ):ComponentResult; 
  129.  INLINE $2F3C,$4,$50E,$7000,$A82A;
  130. FUNCTION MediaSetMatrix (ci:ComponentInstance; VAR trackMovieMatrix :MatrixRecord ) :ComponentResult;
  131.  INLINE $2F3C,$4,$50F,$7000,$A82A;
  132. FUNCTION MediaGetTrackOpaque (ci:ComponentInstance;VAR trackIsOpaque:BOOLEAN ):ComponentResult; 
  133.  INLINE $2F3C,$4,$510,$7000,$A82A;
  134. FUNCTION MediaSetGraphicsMode (ci:ComponentInstance ; mode:LONGINT ; VAR opColor:RGBColor ):ComponentResult; 
  135.  INLINE $2F3C,$8,$511,$7000,$A82A;
  136. FUNCTION MediaGetGraphicsMode (ci:ComponentInstance; VAR mode:LONGINT; VAR opColor:RGBColor ):ComponentResult; 
  137.  INLINE $2F3C,$8,$512,$7000,$A82A;
  138. FUNCTION MediaGSetVolume (ci:ComponentInstance;volume:INTEGER  ):ComponentResult; 
  139.  INLINE $2F3C,$2,$513,$7000,$A82A;
  140. FUNCTION MediaSetSoundBalance (ci:ComponentInstance; balance:INTEGER):ComponentResult; 
  141.  INLINE $2F3C,$2,$514,$7000,$A82A;
  142. FUNCTION MediaGetSoundBalance (ci:ComponentInstance; VAR balance:INTEGER ):ComponentResult; 
  143.  INLINE $2F3C,$4,$515,$7000,$A82A;
  144. FUNCTION MediaGetNextBoundsChange (ci:ComponentInstance; VAR when:TimeValue ):ComponentResult; 
  145.  INLINE $2F3C,$4,$516,$7000,$A82A;
  146. FUNCTION MediaGetSrcRgn (ci:ComponentInstance; rgn:RgnHandle; atMediaTime:TimeValue  ):ComponentResult; 
  147.  INLINE $2F3C,$8,$517,$7000,$A82A;
  148. FUNCTION MediaPreroll (ci:ComponentInstance;time: TimeValue;rate: Fixed  ):ComponentResult; 
  149.  INLINE $2F3C,$8,$518,$7000,$A82A;
  150. FUNCTION MediaSampleDescriptionChanged (ci:ComponentInstance; index:LONGINT ):ComponentResult;
  151.  INLINE $2F3C,$4,$519,$7000,$A82A;
  152. FUNCTION MediaHasCharacteristic (ci:ComponentInstance; characteristic:OSType; VAR hasIt:BOOLEAN ):ComponentResult;
  153.  INLINE $2F3C,$8,$51A,$7000,$A82A;
  154.  
  155. {$ENDC} { UsingMediaHandlers }
  156.  
  157. {$IFC NOT UsingIncludes}
  158.  END.
  159. {$ENDC}
  160.